import request from '@/utils/request';

export async function getPrintDesignFileByPage(params: any) {
  return request('/api/service/getPrintDesignFileByPage', {
    method: 'POST',
    data: params,
  });
}

export async function addPrintDesignFile(params: any) {
  return request('/api/service/addPrintDesignFile', {
    method: 'POST',
    data: params,
  });
}

export async function updatePrintDesignFile(params: any) {
  return request('/api/service/updatePrintDesignFile', {
    method: 'POST',
    data: params,
  });
}

export async function updateFileContent(params: any) {
  return request('/api/service/updateFileContent', {
    method: 'POST',
    data: params,
  });
}

export async function delPrintDesignFile(params: any) {
  return request('/api/service/delPrintDesignFile', {
    method: 'POST',
    data: params,
  });
}

export async function exportPrintDesignFile(params: any) {
  return request('/api/service/exportPrintDesignFile', {
    method: 'POST',
    data: params,
    responseType: 'blob',
  });
}
export default {
  getPrintDesignFileByPage,
  addPrintDesignFile,
  updatePrintDesignFile,
  delPrintDesignFile,
  exportPrintDesignFile,
};
